﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Day02PM
{
    class Program
    {
        static void Main2(string[] args)
        {
            //Employee emp = new Employee() { Name = "张三", JobName = "普通员工", BasicSalary = 3000 };
            //float s1 = emp.CalculateSalary();

            ////emp.JobName = "程序员";//仅仅改变了头衔 实质的薪资没有变化
            ////float s2 = emp.CalculateSalary();

            ////开除普通员工“张三”，重新招聘程序员“张三”
            //emp = new Programmer() { Name = "张三", JobName = "程序员", BasicSalary = 8000, Bonus = 10000 };
            //float s3 = emp.CalculateSalary();
            Employee emp = new Employee() { Name = "张三", JobName = "普通员工", JobObject = new Job() { BasicSalary = 3000 } };
            float s1 = emp.CalculateSalary();
            emp.JobObject = new Programmer() { BasicSalary = 8000, Bonus = 10000 };
            emp.JobName = "程序员";
            float s2 = emp.CalculateSalary();
        }
        /*
         作业：
         图形管理器
         管理所有具体图形，提供计算总面积的功能……
         变换点：圆形、三角形、矩形……
         */

    }
    
}
